package com.yycx.module.bus.client.entity.hy;

import java.math.BigDecimal;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import com.yycx.common.mybatis.base.entity.AbstractEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import com.yycx.common.mybatis.annotation.TableAlias;
/**
 * 认款使用记录
 *
 * @author flyme
 * @date 2023-11-04
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("bus_payment_order")
@TableAlias("bpo")
@ApiModel(value="BusPaymentOrder对象", description="认款使用记录")
public class BusPaymentOrder extends AbstractEntity {

private static final long serialVersionUID=1L;

    @ApiModelProperty(value = "主键")
    @TableId(value = "paymentOrderId", type = IdType.ASSIGN_ID)
    private Long paymentOrderId;

    @ApiModelProperty(value = "认款ID")
    private Long paymentId;

    @ApiModelProperty(value = "认款单号")
    private String paymentNo;

    @ApiModelProperty(value = "银行流水ID")
    private String bankStatementId;

    @ApiModelProperty(value = "认款方式1：实时收款,3:认款记录")
    private Integer amountType;

    @ApiModelProperty(value = "发货方式")
    private Integer sendType;

    @ApiModelProperty(value = "订单ID")
    private String orderId;

    @ApiModelProperty(value = "客户ID")
    private String customId;

    @ApiModelProperty(value = "账套ID")
    private Long companyId;

    @ApiModelProperty(value = "银行ID")
    private Long bankId;

    @ApiModelProperty(value = "银行名称")
    private String bankName;

    @ApiModelProperty(value = "收款日期")
    private Date takeDate;

    @ApiModelProperty(value = "认款日期")
    private Date renDate;

    @ApiModelProperty(value = "收款金额")
    private BigDecimal takeAmount;

    @ApiModelProperty(value = "订单使用金额")
    private BigDecimal useAmount;

    @ApiModelProperty(value = "剩余金额")
    @TableField(exist = false)
    private BigDecimal surplusAmount;

    @ApiModelProperty(value = "是否可用")
    @TableField(exist = false)
    private Boolean used=true;

}
